@import url("https://fonts.googleapis.com/css2?family=Amiri:wght@400;700&display=swap");

body.school-site {
    --gold: #c5922e;
    --blue: #1f4fbf;
    --ink: #243044;
    --cream: #f7f4ef;
    background: var(--cream) !important;
    background-image: none !important;
    color: var(--ink);
    overflow-x: hidden;
}
body.school-site .main-header {
    position: sticky; top: 0; z-index: 40;
    background: rgba(255,255,255,.94) !important;
    border-bottom: 1px solid rgba(36,48,68,.06);
    box-shadow: 0 8px 24px rgba(36,48,68,.04);
}
body.school-site .nav-container {
    width: min(1240px, calc(100% - 1.5rem));
    margin: 0 auto; display: flex; align-items: center; gap: .5rem; min-height: 78px;
}
body.school-site .logo { display: inline-flex; align-items: center; gap: .55rem; min-width: 0; }
body.school-site .sq-logo {
    width: 48px; height: 58px; border-radius: 10px; object-fit: contain;
    border: 1px solid #f3e6c8; background: #fff; box-shadow: 0 6px 16px rgba(36,48,68,.08);
}
body.school-site .logo-text h1 { color: #1d3557; font-size: .95rem; margin: 0; white-space: nowrap; }
body.school-site .logo-text p { display: none; }
body.school-site .nav-link { white-space: nowrap; font-size: .84rem; padding: .4rem .45rem; }
body.school-site .header-actions .btn { padding: .55rem .9rem !important; font-size: .84rem; }
body.school-site .desktop-nav { display: none; }
@media (min-width: 1024px) {
    body.school-site .nav-container {
        display: grid;
        grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
        align-items: center;
    }
    body.school-site .logo { justify-self: start; }
    body.school-site .desktop-nav { display: flex; align-items: center; justify-self: center; gap: .15rem; }
    body.school-site .header-buttons { justify-self: end; }
}
body.school-site .nav-link { color: #31445c; font-weight: 700; }
body.school-site .nav-link.active, body.school-site .nav-link:hover { color: var(--gold); background: transparent; box-shadow: none; }
body.school-site .dropdown { background: #fff; border: 1px solid #f0e6d4; border-radius: 14px; }
body.school-site .header-buttons { flex-shrink: 0; }
body.school-site .header-actions { flex-wrap: nowrap; }
body.school-site .header-actions .btn { white-space: nowrap; }
body.school-site .logo-text h1 { white-space: nowrap; }
body.school-site .header-buttons .btn-login {
    background: var(--blue) !important; color: #fff !important; border: 0 !important; border-radius: 12px !important;
}
body.school-site .header-buttons .btn-register {
    background: #fff !important; color: #d08900 !important; border: 1.5px solid #f0c14b !important; border-radius: 12px !important;
}

.misagh-hero {
    width: min(1180px, calc(100% - 1.5rem));
    margin: 1rem auto 0;
    min-height: 520px;
    display: grid;
    direction: ltr;
    grid-template-columns: 1fr .9fr 1fr;
    align-items: center;
    gap: 1rem;
}
.hero-copy { direction: rtl; }
.arch {
    height: 460px;
    border-radius: 230px 230px 28px 28px;
    overflow: hidden;
    background: #efe8dc;
    border: 8px solid #fff;
    box-shadow: 0 22px 40px rgba(36,48,68,.08);
}
.arch img, .arch video { width: 100%; height: 100%; object-fit: cover; display: block; }
#quran.misagh-wrap {
    width: min(94vw, calc(70vh * 16 / 9), calc(70dvh * 16 / 9));
    max-width: none;
    margin: 1.2rem auto .2rem;
    padding: 0;
}
#quran .sec-title { width: 100%; margin: 0 auto .8rem; }
.quran-photo {
    position: relative;
    width: 100%;
    margin: 0 auto;
    overflow: hidden;
    background: transparent;
    container-type: inline-size;
}
.quran-photo > img {
    width: 100%;
    max-width: 100%;
    margin-inline: 0;
    height: auto !important;
    display: block;
    border-radius: 0;
    background: transparent;
}
.quran-slot {
    position: absolute;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    overflow: hidden;
    direction: rtl;
    padding: .2rem .35rem;
    transition: opacity .45s ease;
}
.quran-photo.fading .quran-slot { opacity: 0; }
.quran-slot-left { left: 22%; top: 24%; width: 24%; height: 48%; }
.quran-slot-right { left: 54%; top: 24%; width: 24%; height: 48%; }
.quran-flip { display: none; }
.quran-slot .ayah {
    font-family: Amiri, "Times New Roman", serif;
    font-size: clamp(1rem, 2.6cqi, 2.15rem);
    line-height: 1.75;
    color: #1b241c;
    margin: 0;
}
.quran-slot .gloss {
    font-size: clamp(.85rem, 1.85cqi, 1.35rem);
    line-height: 1.65;
    color: #2d3a34;
    margin: 0 0 .35rem;
}
.quran-slot small { color: #8d6b2e; font-weight: 700; font-size: clamp(.7rem, 1.25cqi, 1rem); }
.quran-sheet { width: 100%; }
.quran-flip {
    position: absolute;
    inset: 0;
    transform-origin: left center;
    transform-style: preserve-3d;
    z-index: 2;
}
.quran-flip.turning { animation: quran-turn 1.15s ease-in-out forwards; }
.quran-face {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: .45rem;
    background: #f3e7cc;
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
}
.quran-face-back { transform: rotateY(180deg); }
@keyframes quran-turn {
    from { transform: rotateY(0deg); }
    to { transform: rotateY(-180deg); }
}
.hero-copy { text-align: center; }
.hero-copy h2 {
    font-size: clamp(2.4rem, 4.6vw, 4.1rem);
    line-height: 1.25;
    margin: 0 0 1.3rem;
    color: #2f6bff;
    font-weight: 900;
}
.hero-copy em {
    font-style: normal;
    color: #f0a202;
    text-decoration: underline;
    text-underline-offset: 8px;
}
.hero-join {
    display: inline-flex;
    background: var(--blue);
    color: #fff;
    border-radius: 14px;
    padding: .95rem 2.4rem;
    font-weight: 800;
    font-size: 1.05rem;
}

.misagh-wrap { width: min(1180px, calc(100% - 1.5rem)); margin: 2.2rem auto; }

.mushaf-stage {
    position: relative;
    padding: 1.8rem 1rem 1.2rem;
    overflow: hidden;
    border-radius: 28px;
    background:
        radial-gradient(ellipse at 70% 30%, rgba(198,110,40,.28), transparent 42%),
        radial-gradient(ellipse at 50% 0%, rgba(255,220,150,.35), transparent 48%),
        linear-gradient(180deg, #2a1a12 0%, #4a2a18 48%, #1a100c 100%);
}
.mushaf-glow {
    position: absolute;
    inset: 8% 18% auto;
    height: 42%;
    background: radial-gradient(ellipse at center, rgba(255,236,180,.55), transparent 68%);
    filter: blur(8px);
    pointer-events: none;
}
.mushaf-scene {
    position: relative;
    z-index: 1;
    width: min(880px, 100%);
    margin: 0 auto;
    padding-bottom: 58px;
}
.mushaf-book {
    direction: ltr;
    position: relative;
    z-index: 2;
    display: grid;
    grid-template-columns: 58px minmax(0, 1fr) 58px;
    align-items: stretch;
    transform: perspective(1400px) rotateX(8deg);
    transform-style: preserve-3d;
    filter: drop-shadow(0 24px 28px rgba(0,0,0,.45));
}
.cover-board {
    position: relative;
    z-index: 2;
    background:
        radial-gradient(circle at 50% 40%, rgba(230,190,70,.3), transparent 42%),
        linear-gradient(160deg, #1b1b1b 0%, #0d0d0d 55%, #050505 100%);
    box-shadow:
        inset 0 0 0 2px rgba(212,175,55,.85),
        inset 0 0 0 9px rgba(20,12,4,.65),
        inset 0 0 30px rgba(0,0,0,.45);
}
.cover-board::before {
    content: "";
    position: absolute;
    inset: 10px 8px;
    border: 1.5px solid rgba(212,175,55,.7);
    box-shadow: inset 0 0 0 4px rgba(0,0,0,.35), 0 0 0 3px rgba(0,0,0,.25);
    pointer-events: none;
}
.cover-left {
    border-radius: 16px 2px 2px 16px;
    transform: perspective(900px) rotateY(16deg);
    transform-origin: right center;
    margin-right: -6px;
}
.cover-right {
    border-radius: 2px 16px 16px 2px;
    transform: perspective(900px) rotateY(-16deg);
    transform-origin: left center;
    margin-left: -6px;
}
.cover-ornament {
    position: absolute;
    inset: 24% 16%;
    border: 1.5px solid rgba(212,175,55,.85);
    border-radius: 50%;
    box-shadow: inset 0 0 0 5px rgba(0,0,0,.45), 0 0 0 5px rgba(212,175,55,.18);
}
.cover-ornament::before {
    content: "";
    position: absolute;
    inset: 16%;
    border: 1px solid rgba(212,175,55,.7);
    border-radius: 50%;
    background: radial-gradient(circle at 50% 50%, rgba(230,190,70,.8) 0 10%, transparent 11%);
}
.mushaf-pages {
    position: relative;
    display: grid;
    grid-template-columns: 1fr 1fr;
    min-height: 390px;
    perspective: 2200px;
    background: linear-gradient(180deg, #fff8e8, #f3e6c8);
    border-radius: 2px;
    overflow: hidden;
    box-shadow:
        inset 0 0 0 1px rgba(168,124,42,.4),
        0 0 0 2px rgba(30,18,8,.55),
        0 -18px 40px rgba(255,230,170,.25);
}
.page-stack {
    position: absolute;
    top: 10px; bottom: 10px; right: -8px;
    width: 12px;
    background: repeating-linear-gradient(to right, #f7ecd4 0 1px, #dcc79a 1px 2px);
    border-radius: 0 3px 3px 0;
    box-shadow: 2px 0 8px rgba(0,0,0,.2);
    z-index: 1;
}
.book-spine {
    position: absolute;
    top: 0; bottom: 0; left: 50%;
    width: 24px;
    transform: translateX(-50%);
    background: linear-gradient(90deg, rgba(0,0,0,.28), rgba(255,255,255,.7) 46%, rgba(0,0,0,.3));
    z-index: 5;
    pointer-events: none;
}
.bookmark-ribbons {
    position: absolute;
    left: 50%;
    bottom: -38px;
    transform: translateX(-50%);
    display: flex;
    gap: 7px;
    z-index: 7;
}
.ribbon {
    width: 10px;
    height: 46px;
    border-radius: 0 0 3px 3px;
    clip-path: polygon(0 0, 100% 0, 100% 78%, 50% 100%, 0 78%);
    box-shadow: 0 4px 8px rgba(0,0,0,.25);
}
.ribbon-gold { background: linear-gradient(#f0c14b, #c7922a); }
.ribbon-red { background: linear-gradient(#c4473a, #8c241c); height: 40px; }
.ribbon-green { background: linear-gradient(#2f8a58, #1a5a38); height: 52px; }
.leaf, .turn-face {
    display: flex;
    align-items: stretch;
    justify-content: center;
    padding: .7rem;
    direction: rtl;
    background:
        linear-gradient(90deg, rgba(90,60,20,.1), transparent 14%, transparent 86%, rgba(90,60,20,.08)),
        linear-gradient(#fff8e8, #f4e7cb);
}
.page-frame {
    position: relative;
    width: 100%;
    min-height: 340px;
    display: flex;
    align-items: stretch;
    padding: 11% 10.5%;
    background: url("/assets/images/campus/tazhib-frame.svg") center / 100% 100% no-repeat;
    box-shadow: 0 2px 10px rgba(0,0,0,.08);
}
.page-inner {
    position: relative;
    z-index: 1;
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: .6rem .4rem;
    background: transparent;
    border: 0;
    box-shadow: none;
}
.bismillah {
    font-family: Amiri, "Times New Roman", serif;
    font-size: 1rem;
    color: #8a6a28;
    margin: 0 0 .9rem;
}
.leaf .ayah, .turn-face .ayah, .leaf-right .ayah {
    font-family: Amiri, "Times New Roman", serif;
    font-size: clamp(1.35rem, 2.1vw, 1.9rem);
    line-height: 2.05;
    color: #1a221c;
    margin: 0;
}
.leaf .gloss, .turn-face .gloss {
    font-size: 1rem;
    line-height: 2;
    color: #3d4a44;
    margin: 0 0 .7rem;
}
.leaf small, .turn-face small {
    color: #9a7430;
    font-weight: 700;
}
.page-turner {
    position: absolute;
    top: 0; right: 0;
    width: 50%;
    height: 100%;
    transform-origin: left center;
    transform-style: preserve-3d;
    z-index: 6;
}
.page-turner.turning {
    animation: mushaf-flip 1.25s cubic-bezier(.2,.7,.2,1) forwards;
}
.turn-face {
    position: absolute;
    inset: 0;
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
}
.turn-front { box-shadow: -10px 0 22px rgba(0,0,0,.18); }
.turn-back {
    transform: rotateY(180deg);
    background:
        linear-gradient(270deg, rgba(90,60,20,.12), transparent 16%),
        linear-gradient(#fff8e8, #f4e7cb);
}
@keyframes mushaf-flip {
    0% { transform: rotateY(0deg); }
    100% { transform: rotateY(-180deg); }
}
.rehal {
    position: absolute;
    left: 50%;
    bottom: 2px;
    width: min(560px, 84%);
    height: 92px;
    transform: translateX(-50%);
    z-index: 1;
    pointer-events: none;
}
.rehal-arm {
    position: absolute;
    top: 8px;
    width: 18px;
    height: 78px;
    background:
        linear-gradient(90deg, rgba(212,175,55,.55), transparent 35%, transparent 65%, rgba(212,175,55,.4)),
        linear-gradient(180deg, #7a3a62, #4a2040 55%, #2c1226);
    border: 1px solid rgba(212,175,55,.5);
    border-radius: 8px;
    box-shadow: 0 10px 18px rgba(0,0,0,.35), inset 0 1px 0 rgba(255,255,255,.18);
}
.rehal-arm::after {
    content: "";
    position: absolute;
    left: -4px; right: -4px; bottom: -2px;
    height: 14px;
    border-radius: 4px;
    background: linear-gradient(180deg, #d4af37, #9a7420);
    box-shadow: 0 2px 4px rgba(0,0,0,.25);
}
.rehal-arm-l {
    left: 28%;
    transform: rotate(28deg);
    transform-origin: bottom center;
}
.rehal-arm-r {
    right: 28%;
    transform: rotate(-28deg);
    transform-origin: bottom center;
}
.rehal-base {
    position: absolute;
    left: 18%;
    right: 18%;
    bottom: 0;
    height: 18px;
    border-radius: 50%;
    background: radial-gradient(ellipse at center, rgba(0,0,0,.5), transparent 72%);
}

.panel-frame {
    display: grid; grid-template-columns: 220px 1fr; gap: 1rem;
    background: #fff; border: 1px solid rgba(36,48,68,.06); border-radius: 28px; padding: 1rem;
    box-shadow: 0 16px 40px rgba(36,48,68,.05);
}
.event-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: .7rem; }
.event-row article { background: #f8fbff; border-radius: 18px; padding: .7rem; }
.event-row img { width: 100%; height: 120px; object-fit: cover; border-radius: 12px; }
.event-row h3 { font-size: .95rem; margin: .7rem 0 .4rem; min-height: 2.6em; }
.event-row .line { display: block; height: 2px; width: 42%; margin: .45rem 0; background: #e4c98a; border-radius: 4px; }
.event-row small { color: #7b8798; }
.panel-frame aside { text-align: center; align-self: center; }
.panel-frame aside h2 { color: var(--gold); font-size: 1.8rem; margin: 0; }
.ghost { display: inline-block; margin-top: 1rem; border: 1px solid #d7deea; border-radius: 12px; padding: .45rem .9rem; }

.sec-title { text-align: center; margin-bottom: 1rem; }
.sec-title h2 { color: #1d3557; font-size: 1.85rem; margin: 0; font-weight: 800; }
.sec-title h2::after {
    content: "";
    display: block;
    width: 42px; height: 2px;
    margin: .45rem auto 0;
    background: var(--gold);
}
.sec-title p { color: #66758a; margin: .3rem 0 0; }
.level-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: .8rem; }
.level-card {
    background: linear-gradient(180deg, #2457c5, #1d4eae);
    color: #fff;
    border-radius: 22px;
    padding: 1.35rem 1.05rem 1rem;
    min-height: 250px;
    display: flex; flex-direction: column; gap: .45rem;
    box-shadow: 0 14px 28px rgba(31,79,191,.16);
}
.level-card h3 { margin: .4rem 0; font-size: 1.15rem; }
.level-card p, .level-card a.phone { color: #fff; font-size: .82rem; line-height: 1.8; margin: 0; }
.level-card .more {
    margin-top: auto; text-align: center; color: #fff; border-top: 1px solid rgba(255,255,255,.35); padding-top: .55rem; font-weight: 800;
}
.centers { display: grid; grid-template-columns: 360px 1fr; gap: 1.5rem; align-items: center; }
.center-copy h2 { color: var(--gold); font-size: 2rem; margin: 0; }
.center-copy ul { list-style: none; margin: 1rem 0 0; padding: 0; }
.center-copy li {
    display: flex; justify-content: space-between; align-items: center;
    padding: .85rem 0; border-bottom: 1px solid #f0e6d4; font-weight: 700;
}
.center-copy i {
    width: 28px; height: 28px; border-radius: 50%; background: #fff4d6; color: var(--gold);
    display: grid; place-items: center; font-size: .8rem;
}
.oval {
    width: 300px; height: 380px; border-radius: 180px; overflow: hidden;
    border: 8px solid #fff; outline: 1px solid #ead7a4; justify-self: center; background: #efe8dc;
    box-shadow: 0 18px 36px rgba(36,48,68,.08);
}
.oval img { width: 100%; height: 100%; object-fit: cover; }

.media-board {
    display: grid; grid-template-columns: 1fr; gap: 1.15rem; align-items: start; color: #fff;
}
.media-copy { text-align: center; padding-block: 0; }
.media-copy h2 {
    margin: 0; display: block;
    font-family: Vazir, Shabnam, sans-serif; font-size: 1.85rem; font-weight: 800; line-height: 1.4; color: #fff;
}
.media-copy h2::after {
    content: ""; display: block; width: 42px; height: 2px; margin: .45rem auto 0; background: #f0c14b;
}
.media-copy p {
    margin: .55rem auto 0; max-width: none;
    font-family: Vazir, Shabnam, sans-serif; font-size: 1rem; font-weight: 500; line-height: 1.9;
    color: rgba(255,255,255,.92);
}
.media-mosaic {
    display: grid; grid-template-columns: 1.35fr 1fr 1fr; grid-template-rows: 176px 176px; gap: .65rem;
}
.media-mosaic .reel { grid-row: 1 / span 2; grid-column: 1; margin: 0; max-width: none; height: 100%; border-radius: 18px; }
.media-mosaic .reel img { width: 100%; height: 100%; object-fit: cover; }
.media-mosaic > img { width: 100%; height: 100%; object-fit: cover; border-radius: 16px; display: block; }
.reel { position: relative; overflow: hidden; background: #123; }
.reel-play {
    position: absolute; left: .8rem; bottom: .8rem; top: auto; transform: none;
    width: 52px; height: 52px; border: 0; border-radius: 50%;
    background: rgba(255,255,255,.94); color: #1d4e89; font-weight: 800; cursor: pointer;
}

body.school-site .footer {
    background: transparent !important;
    color: var(--ink) !important;
    border-top: 0;
    padding-top: 1rem;
}
body.school-site .footer h3, body.school-site .footer h4, body.school-site .footer a, body.school-site .footer p, body.school-site .footer li { color: #31445c !important; }
body.school-site .footer h4 { border-right: 0 !important; box-shadow: inset 0 -3px 0 #f0c14b; display: inline-block; padding-bottom: .2rem; color: #1d3557 !important; }
body.school-site .footer-bottom { background: #f0a202; color: #fff; border: 0; border-radius: 18px; padding: .9rem 1rem; margin-top: .5rem; }
body.school-site .footer-bottom p, body.school-site .footer-bottom a { color: #fff !important; }
body.school-site .social-links a { background: rgba(255,255,255,.22); color: #fff !important; }

.school-chat-fab {
    position: fixed;
    right: 1.1rem;
    bottom: 1.1rem;
    z-index: 90;
    width: 58px;
    height: 70px;
    padding: 4px;
    border: 1px solid #d5ebf8;
    border-radius: 14px;
    background: #fff;
    box-shadow: 0 12px 26px rgba(74, 163, 232, .22);
    cursor: pointer;
    display: grid;
    place-items: center;
}
.school-chat-fab img {
    width: 46px;
    height: 56px;
    max-width: none;
    object-fit: contain;
    display: block;
}
.school-chat-mark,
.bot-avatar-farz img {
    width: 100%;
    height: 100%;
    max-width: none;
    object-fit: contain;
    display: block;
}
.school-chat-dot {
    position: absolute;
    top: 4px;
    left: 4px;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #2fbe6a;
    border: 2px solid #fff;
}
.school-chat-panel {
    position: fixed;
    right: 1.1rem;
    bottom: 5.8rem;
    z-index: 91;
    width: min(360px, calc(100vw - 1.4rem));
    height: min(460px, calc(100vh - 7.4rem));
    display: none;
    flex-direction: column;
    background: #f4fbff;
    border: 1px solid #c5e4f8;
    border-radius: 22px;
    overflow: hidden;
    box-shadow: 0 22px 48px rgba(74, 163, 232, .22);
}
.school-chat-panel.active { display: flex; }
.school-chat-panel::before {
    content: "";
    display: block;
    height: 4px;
    background: linear-gradient(90deg, #5eb6f0, #ff9f1c 52%, #2fbe6a);
}
.school-chat-head {
    display: flex;
    align-items: center;
    gap: .7rem;
    padding: .75rem .85rem .7rem;
    background: #e7f4ff;
    border-bottom: 1px solid #c5e4f8;
}
.school-chat-mark {
    width: 42px;
    height: 52px;
    flex-shrink: 0;
    padding: 2px;
    background: #fff;
    border: 1px solid #d5ebf8;
    border-radius: 10px;
}
.school-chat-title { min-width: 0; flex: 1; }
.school-chat-head strong {
    display: block;
    color: #1a6fb5;
    font-size: .95rem;
    font-weight: 800;
}
.school-chat-head span {
    display: inline-flex;
    align-items: center;
    gap: .35rem;
    margin-top: .15rem;
    color: #1f9d55;
    font-size: .72rem;
    font-weight: 800;
}
.school-chat-head span::before {
    content: "";
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #2fbe6a;
}
.school-chat-head button {
    width: 32px;
    height: 32px;
    border: 1px solid #ffc57a;
    border-radius: 10px;
    background: #fff;
    color: #e07a00;
    cursor: pointer;
    flex-shrink: 0;
}
.school-chat-messages {
    flex: 1;
    overflow: auto;
    padding: .9rem .85rem;
    background: #f4fbff;
    display: flex;
    flex-direction: column;
    gap: .65rem;
}
.message-user-farz, .message-bot-farz {
    display: flex;
    gap: .45rem;
    align-items: flex-end;
    max-width: 92%;
}
.message-bot-farz { align-self: flex-start; }
.message-user-farz { align-self: flex-end; flex-direction: row-reverse; }
.user-avatar-farz, .bot-avatar-farz {
    width: 30px;
    height: 30px;
    border-radius: 10px;
    display: grid;
    place-items: center;
    flex-shrink: 0;
    background: #fff;
    color: #fff;
    font-size: .72rem;
    border: 1px solid #c5e4f8;
    overflow: hidden;
}
.user-avatar-farz { background: #2fbe6a; border-color: #2fbe6a; }
.user-text-farz, .bot-text-farz {
    padding: .7rem .85rem;
    border-radius: 16px;
    font-size: .84rem;
    line-height: 1.8;
    min-width: 3.2rem;
}
.user-text-farz {
    background: #5eb6f0;
    color: #fff;
    border-bottom-left-radius: 5px;
}
.bot-text-farz {
    background: #fff;
    color: #1a4f78;
    border: 1px solid #c5e4f8;
    border-bottom-right-radius: 5px;
}
.typing-farz { display: flex; gap: 4px; padding: .7rem .8rem; background: #fff; border-radius: 14px; }
.typing-farz span {
    width: 6px; height: 6px; border-radius: 50%; background: #ff9f1c;
    animation: chat-dot 1s infinite ease-in-out;
}
.typing-farz span:nth-child(2) { animation-delay: .15s; }
.typing-farz span:nth-child(3) { animation-delay: .3s; }
@keyframes chat-dot {
    0%, 80%, 100% { transform: translateY(0); opacity: .45; }
    40% { transform: translateY(-4px); opacity: 1; }
}
.school-chat-quick {
    display: flex;
    flex-wrap: wrap;
    gap: .4rem;
    padding: .55rem .75rem;
    border-top: 1px solid #c5e4f8;
    background: #fff;
}
.school-chat-quick button {
    border: 1px solid #ffc57a;
    background: #fff7ec;
    color: #1f9d55;
    border-radius: 999px;
    padding: .32rem .75rem;
    font-size: .75rem;
    font-weight: 800;
    cursor: pointer;
}
.school-chat-quick button:hover { background: #ffe8c7; }
.school-chat-input {
    display: flex;
    gap: .45rem;
    padding: .7rem;
    border-top: 1px solid #c5e4f8;
    background: #fff;
}
.school-chat-input input {
    flex: 1;
    min-width: 0;
    border: 1px solid #b9ddf7;
    border-radius: 12px;
    background: #f4fbff;
    color: #1a4f78;
    padding: .7rem .8rem;
    font: inherit;
    font-size: .86rem;
    outline: none;
}
.school-chat-input input:focus { border-color: #ff9f1c; }
.school-chat-input button {
    width: 44px;
    border: 0;
    border-radius: 12px;
    background: #2fbe6a;
    color: #fff;
    cursor: pointer;
    flex-shrink: 0;
}
body.school-site .scroll-top { bottom: 5.8rem; right: 1.25rem; }

@media (max-width: 1024px) {
    body.school-site .header-actions { display: flex !important; gap: .35rem; }
    body.school-site .header-actions .btn span { display: none; }
    body.school-site .header-actions .btn { padding: .65rem .75rem !important; min-width: 40px; }
}

@media (max-width: 980px) {
    .misagh-hero {
        grid-template-columns: 1fr 1fr;
        direction: rtl;
        gap: .8rem;
        min-height: 0;
        align-items: start;
    }
    .hero-copy {
        grid-column: 1 / -1;
        order: -1;
        padding: .4rem 0 .2rem;
    }
    .hero-copy h2 { font-size: clamp(1.8rem, 7vw, 2.5rem); margin-bottom: .9rem; }
    .arch { height: 280px; border-width: 5px; }
    .event-row, .level-grid, .media-row, .centers, .panel-frame { grid-template-columns: 1fr 1fr; }
    .panel-frame aside { grid-column: 1 / -1; }
    .oval { width: 220px; height: 280px; }
    .mushaf-book {
        grid-template-columns: 36px minmax(0, 1fr) 36px;
        transform: perspective(1200px) rotateX(5deg);
    }
    .cover-left, .cover-right { transform: none; margin: 0; }
    .mushaf-pages { min-height: 320px; }
    .page-frame { min-height: 260px; padding: 11% 10%; }
    .mushaf-scene { padding-bottom: 48px; }
}

@media (max-width: 680px) {
    body.school-site .nav-container {
        width: calc(100% - 1rem);
        min-height: 64px;
        gap: .3rem;
    }
    body.school-site .logo {
        display: inline-flex !important;
        align-items: center;
        gap: .45rem;
        min-width: 0;
        flex: 1 1 auto;
        max-width: calc(100% - 148px);
    }
    body.school-site .sq-logo { width: 40px; height: 40px; flex-shrink: 0; display: block !important; }
    body.school-site .logo-text { display: block !important; min-width: 0; }
    body.school-site .logo-text h1 { font-size: .78rem; max-width: 100%; overflow: hidden; text-overflow: ellipsis; }
    body.school-site .header-buttons { display: flex; align-items: center; gap: .3rem; }
    body.school-site .header-actions { display: flex !important; }
    body.school-site .mobile-toggle { display: inline-flex !important; }
    .quran-slot-left { left: 20%; top: 23%; width: 26%; height: 50%; }
    .quran-slot-right { left: 53%; top: 23%; width: 26%; height: 50%; }
    .school-chat-fab { width: 56px; height: 56px; right: .85rem; bottom: .85rem; }
    .school-chat-panel { right: .85rem; bottom: 4.7rem; height: min(420px, calc(100vh - 6rem)); }
    .misagh-wrap { width: calc(100% - 1.1rem); margin: 1.25rem auto; }
    .misagh-hero { grid-template-columns: 1fr 1fr; gap: .55rem; }
    .arch { height: 210px; border-width: 4px; }
    .hero-copy h2 { font-size: 1.65rem; }
    .hero-join { width: auto; padding: .8rem 1.4rem; font-size: .95rem; }
    .event-row, .level-grid, .media-row, .centers, .panel-frame { grid-template-columns: 1fr; }
    .panel-frame { padding: .85rem; overflow: hidden; }
    .event-row article { overflow: hidden; }
    .event-row img { height: 150px; }
    .event-row h3 { min-height: 0; font-size: .92rem; }
    .level-card { min-height: 0; }
    .centers { justify-items: center; }
    .oval { width: 180px; height: 230px; margin-bottom: .4rem; }
    .media-row img { height: 170px; }
    .reel img { height: 190px; }
    .mushaf-stage { padding: .85rem .55rem .7rem; border-radius: 18px; }
    .mushaf-scene { padding-bottom: 42px; }
    .mushaf-book {
        grid-template-columns: 18px minmax(0, 1fr) 18px;
        width: 100%;
        transform: perspective(900px) rotateX(4deg);
    }
    .cover-board::before { inset: 6px 4px; }
    .cover-ornament { inset: 28% 10%; }
    .mushaf-pages { min-height: 210px; }
    .page-stack { display: none; }
    .leaf, .turn-face { padding: .28rem; }
    .page-frame { min-height: 170px; padding: 12% 11%; }
    .page-inner { padding: .35rem .2rem; }
    .bismillah { font-size: .66rem; margin-bottom: .35rem; }
    .leaf .ayah, .turn-face .ayah, .leaf-right .ayah { font-size: .9rem; line-height: 1.65; }
    .leaf .gloss, .turn-face .gloss { font-size: .78rem; line-height: 1.55; margin-bottom: .35rem; }
    .leaf small, .turn-face small { font-size: .68rem; }
    .book-spine { width: 10px; }
    .ribbon { width: 7px; height: 34px; }
    .ribbon-red { height: 30px; }
    .ribbon-green { height: 38px; }
    .bookmark-ribbons { bottom: -28px; gap: 5px; }
    .rehal { height: 54px; width: min(360px, 86%); }
    .rehal-arm { height: 12px; bottom: 12px; }
    .sec-title h2 { font-size: 1.35rem; }
    .panel-frame aside h2, .center-copy h2, .media-panel h2 { font-size: 1.3rem; }
    body.school-site .footer .container { padding-inline: .75rem; }
    body.school-site .footer-grid { grid-template-columns: 1fr !important; gap: 1.1rem; }
}

@media (prefers-reduced-motion: reduce) {
    .quran-flip.turning, .page-turner.turning, .ticker-track { animation: none; }
}

.news-ticker {
    display: flex; align-items: stretch; height: 40px; overflow: hidden;
    background: #fffdf8; color: #1d3557; border-top: 1px solid #f0e6d4;
}
.news-ticker strong {
    display: grid; place-items: center; flex-shrink: 0; padding: 0 .85rem;
    background: transparent; color: #8d6b2e; font-size: .78rem; border-left: 1px solid #f0e6d4;
}
.ticker-viewport { overflow: hidden; flex: 1; min-width: 0; display: flex; align-items: center; justify-content: flex-end; direction: ltr; }
.ticker-track { display: flex; width: max-content; direction: ltr; animation: ticker-move 42s linear infinite; }
.ticker-group { display: flex; direction: rtl; align-items: center; gap: 2.2rem; padding-inline-start: 2.2rem; }
.ticker-group span { white-space: nowrap; font-size: .86rem; direction: rtl; unicode-bidi: isolate; }
.ticker-group span::before { content: ""; display: inline-block; width: 6px; height: 6px; margin-left: .7rem; border-radius: 50%; background: #c5922e; vertical-align: middle; }
@keyframes ticker-move { from { transform: translateX(0); } to { transform: translateX(50%); } }
.news-ticker:hover .ticker-track { animation-play-state: paused; }

.band { width: 100%; padding: 1.7rem 0 2rem; }
.band > .misagh-wrap, .band > .misagh-hero, .band > #quran.misagh-wrap { margin-top: 0; margin-bottom: 0; }
.band-hero { background: linear-gradient(180deg, #fff7ea 0%, #f4e4c8 100%); }
.band-quran { background: #f3ebdd; }
.band-events { background: #e8eef6; }
.band-schools { background: #e5f1e8; }
.band-stars { background: #e8edf7; }
.band-centers { background: #f6efe4; }
.band-voices { background: #fffdf8; }
.band-media { background: #1d4eae; padding-bottom: 2.2rem; }
.band-media .media-panel { background: transparent; box-shadow: none; }

body.page-home { -webkit-user-select: none; user-select: none; -webkit-touch-callout: none; }
body.page-home input, body.page-home textarea { -webkit-user-select: text; user-select: text; }
@media print {
    body.page-home .band, body.page-home .news-ticker { display: none !important; }
}

.podium {
    width: min(980px, 100%);
    margin: 0 auto;
    padding-top: 2.75rem;
    display: grid;
    grid-template-columns: 1fr 1.12fr 1fr;
    align-items: end;
    gap: .9rem;
    transition: opacity .35s ease;
}
.podium.switching { opacity: 0; }
.podium article {
    background: #fff; border-radius: 22px; padding: .7rem .7rem .95rem; text-align: center;
    border: 1px solid #e4eaf4; box-shadow: 0 12px 28px rgba(36,48,68,.06);
}
.podium img { width: 100%; height: 230px; object-fit: cover; object-position: center top; border-radius: 16px; display: block; }
.podium strong { display: block; margin-top: .7rem; color: #1d3557; }
.podium small { color: #8d6b2e; font-weight: 800; }
.podium .rank-1 { transform: translateY(-26px); border-color: #f0c14b; box-shadow: 0 16px 32px rgba(197,146,46,.16); }
.podium .rank-1 img { height: 280px; }
.star-note { margin: .35rem 0 0; color: #6d7c90; font-size: .82rem; }
.level-page .more, .center-page .more, .event-page .more { display: inline-block; margin-top: .7rem; color: #1d4e89; font-weight: 800; }
body.school-site .footer .map-actions a { color: #fff !important; }

.voice-3d {
    position: relative; max-width: 1080px; margin: .2rem auto 0;
    display: grid; grid-template-columns: 52px 1fr 52px; align-items: center;
    grid-template-areas: "scene scene scene" "prev dots next";
    gap: .35rem .4rem; padding: 0 0 1.2rem;
}
.voice-scene {
    grid-area: scene; position: relative; height: 390px;
    perspective: 1200px; transform-style: preserve-3d;
}
.voice-scene::after {
    content: ""; position: absolute; left: 22%; right: 22%; bottom: 28px; height: 34px;
    background: radial-gradient(ellipse at center, rgba(197,146,46,.28), transparent 72%);
    pointer-events: none;
}
.voice-card {
    position: absolute; left: 50%; top: 44%; width: min(440px, 46%);
    margin: 0; padding: 1.5rem 1.4rem 1.25rem; border-radius: 28px;
    background:
        linear-gradient(180deg, rgba(255,255,255,.55), transparent 28%),
        linear-gradient(165deg, #fff 0%, #fff8ec 62%, #f6e7c4 100%);
    border: 1px solid #ead7a4;
    box-shadow: 0 18px 36px rgba(36,48,68,.1), inset 0 0 0 1px rgba(255,255,255,.7);
    direction: rtl; text-align: right;
    transform-style: preserve-3d;
    transition: transform .7s cubic-bezier(.22,.8,.28,1), opacity .7s ease, box-shadow .7s ease;
    cursor: pointer;
}
.voice-card.is-active {
    border-color: #e2b657;
    box-shadow:
        0 0 0 1px rgba(226,182,87,.45),
        0 30px 54px rgba(197,146,46,.22),
        0 16px 30px rgba(36,48,68,.12);
    cursor: default;
}
.qmark { display: block; font-family: Amiri, serif; font-size: 3.4rem; line-height: .65; color: #e2b657; margin-bottom: .35rem; }
.voice-card p { margin: 0 0 .95rem; line-height: 1.95; font-size: 1.02rem; min-height: 5.6rem; }
.who { display: flex; align-items: center; gap: .65rem; }
.who i {
    width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center;
    background: #1d3557; color: #f0c14b; font-style: normal; font-weight: 800;
    box-shadow: inset 0 0 0 2px #f0c14b;
}
.who strong { display: block; color: #1d3557; font-size: .9rem; }
.who small { color: #8d6b2e; }
.voice-nav {
    position: static; z-index: 6; width: 46px; height: 46px; border-radius: 50%;
    border: 1px solid #ead7a4; background: #fff; color: #1d3557; cursor: pointer;
    box-shadow: 0 10px 20px rgba(36,48,68,.08); justify-self: center;
    display: grid; place-items: center; padding: 0;
}
.voice-prev { grid-area: prev; }
.voice-next { grid-area: next; }
.voice-dots { grid-area: dots; display: flex; justify-content: center; align-items: center; gap: .4rem; margin: 0; }
.voice-dots button {
    width: 8px; height: 8px; border: 0; border-radius: 99px; padding: 0; background: #e2d3b4; cursor: pointer;
}
.voice-dots button.is-on { width: 22px; background: #c5922e; }

.visit-board {
    width: 100%; margin: 0 auto 1.2rem;
    display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 0; align-items: stretch;
    background: #fff; border: 1px solid #e4d7be; border-radius: 22px; padding: 0; overflow: hidden;
    box-shadow: 0 16px 34px rgba(36,48,68,.05);
}
.visit-copy { padding: 1.25rem 1.4rem 1.15rem; display: flex; flex-direction: column; min-width: 0; }
.visit-copy h2 {
    margin: 0; padding-bottom: .7rem; border-bottom: 1px solid #eadfce;
    color: #1d3557; font-size: 1.28rem; display: flex; align-items: center; gap: .65rem;
}
.visit-copy h2::before { content: ""; width: 22px; height: 2px; background: #c5922e; flex: none; }
.visit-copy p {
    margin: 0; padding: .85rem 0; line-height: 1.95; color: #526277; font-weight: 500;
    border-bottom: 1px solid #eadfce;
}
.visit-copy ul { list-style: none; margin: 0; padding: 0; }
.visit-copy li {
    display: grid; grid-template-columns: 38px minmax(0, 1fr); gap: .75rem; align-items: center;
    padding: .8rem 0; border-bottom: 1px solid #eadfce; color: #1d3557; font-weight: 700;
}
.visit-copy i {
    width: 38px; height: 38px; margin: 0; border-radius: 10px;
    display: grid; place-items: center; color: #c5922e;
    background: #fffaf1; border: 1px solid #ead7a4;
}
.visit-copy small { display: block; margin-bottom: .12rem; color: #8d6b2e; font-size: .74rem; font-weight: 800; }
.visit-copy li span { display: block; line-height: 1.7; font-weight: 700; }
.visit-map {
    width: 100%; height: 100%; min-height: 360px; border-radius: 0; overflow: hidden;
    background: #efe8dc; justify-self: stretch; border-inline-start: 1px solid #eadfce;
}
.visit-map iframe { width: 100%; height: 100%; border: 0; display: block; }
.map-actions { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: auto; padding-top: .95rem; }
.map-actions a {
    background: #1d3557; color: #fff !important; border-radius: 10px;
    min-height: 38px; padding: 0 .95rem; font-size: .82rem; font-weight: 800;
    display: inline-flex; align-items: center;
}

.quick-contact {
    position: fixed; left: 1.1rem; bottom: 1.1rem; z-index: 90;
    display: flex; flex-direction: column; gap: .5rem;
}
.qc-item {
    display: flex; align-items: center; gap: .55rem; min-height: 50px;
    padding: 5px 5px 5px 14px; border-radius: 16px;
    background: #fff; color: #1d3557 !important; font-weight: 800; font-size: .86rem;
    border: 1px solid #eadfce; box-shadow: 0 10px 22px rgba(36,48,68,.13); text-decoration: none;
    transition: transform .18s ease, box-shadow .18s ease;
}
.qc-item:hover { transform: translateY(-2px); box-shadow: 0 14px 26px rgba(36,48,68,.18); }
.qc-mark {
    width: 38px; height: 38px; border-radius: 12px; display: grid; place-items: center; flex-shrink: 0;
}
.qc-bale .qc-mark { background: #22c55e; }
.qc-call .qc-mark { background: #1d3557; }
.qc-call .qc-mark svg { transform: translateY(-1px); }
.qc-item svg { display: block; }
.qc-label { line-height: 1; letter-spacing: 0; }
body.school-site .quick-contact a,
body.school-site .quick-contact .qc-label { color: #1d3557 !important; }

.site-page { width: min(1180px, calc(100% - 1.5rem)); margin: 0 auto 2.2rem; }
.site-page-head { display: grid; grid-template-columns: 1.15fr .75fr; gap: 1.4rem; align-items: center; padding: 1.3rem 0 .4rem; }
.site-page-head h1 { margin: .15rem 0 .4rem; font-size: clamp(1.8rem, 3vw, 2.5rem); color: #1d3557; }
.site-page-head p { margin: 0; color: #526277; line-height: 1.9; }
.site-page-mark {
    width: 100%; height: 280px; object-fit: cover; display: block;
    border-radius: 150px 150px 26px 26px; border: 8px solid #fff;
    box-shadow: 0 18px 36px rgba(36,48,68,.08);
}
.crumb { color: #8d6b2e; font-weight: 800; font-size: .82rem; margin: 0; }
.story-list { display: grid; gap: 1rem; margin-top: 1rem; }
.story {
    display: grid; grid-template-columns: 300px 1fr; background: #fff; border-radius: 28px; overflow: hidden;
    border: 1px solid rgba(36,48,68,.06); box-shadow: 0 14px 30px rgba(36,48,68,.05);
}
.story img { width: 100%; height: 100%; min-height: 230px; object-fit: cover; display: block; }
.story-body { padding: 1.25rem 1.35rem; display: flex; flex-direction: column; justify-content: center; }
.story-index { color: #c5922e; font-weight: 800; }
.story h2 { margin: .15rem 0 .4rem; color: #1d3557; }
.story p { margin: 0; line-height: 1.9; color: #3d4d63; }
.story .pill {
    display: inline-block; margin-top: .85rem; background: #1d4e89; color: #fff; border-radius: 12px;
    padding: .55rem 1rem; font-weight: 800; width: fit-content;
}
.faq-list { display: grid; gap: .75rem; margin-top: 1rem; }
.faq-list details { background: #fff; border-radius: 22px; border: 1px solid #eadfce; padding: 0 1.15rem; box-shadow: 0 10px 24px rgba(36,48,68,.04); }
.faq-list details[open] { background: #fffaf1; }
.faq-list summary { cursor: pointer; font-weight: 800; color: #1d3557; padding: 1rem 0; list-style: none; display: flex; justify-content: space-between; gap: 1rem; font-size: 1.02rem; }
.faq-list summary::-webkit-details-marker { display: none; }
.faq-list summary::after { content: "+"; color: #c5922e; font-size: 1.4rem; line-height: 1; }
.faq-list details[open] summary::after { content: "–"; }
.faq-list details p { margin: 0 0 1rem; line-height: 1.95; color: #3d4d63; }
.contact-layout { display: grid; grid-template-columns: .85fr 1.15fr; gap: 1rem; margin-top: 1rem; }
.contact-layout form, .soft-card { background: #fff; border-radius: 24px; padding: 1.15rem; border: 1px solid #eadfce; box-shadow: 0 12px 28px rgba(36,48,68,.05); }
.contact-layout form { display: grid; gap: .7rem; }
.contact-layout input, .contact-layout textarea { width: 100%; border: 1px solid #e4d8c4; border-radius: 12px; padding: .75rem .8rem; font: inherit; background: #fffdf8; }
.contact-layout button { border: 0; border-radius: 12px; background: #1d4e89; color: #fff; padding: .8rem 1rem; font-weight: 800; cursor: pointer; }
.form-note { min-height: 1.4rem; color: #1d3557; font-weight: 700; }
body.school-site .footer .visit-copy h2,
body.school-site .footer .visit-copy li,
body.school-site .footer .visit-copy span { color: #1d3557 !important; }
body.school-site .footer .visit-copy p { color: #526277 !important; }
body.school-site .footer .visit-copy small { color: #8d6b2e !important; }
body.school-site .footer .map-actions a,
body.school-site .map-actions a { color: #fff !important; }

@media (max-width: 800px) {
    .podium { grid-template-columns: 1fr; padding-top: 0; }
    .podium .rank-1 { transform: none; order: -1; }
    .site-page-head, .story, .contact-layout, .visit-board, .media-board { grid-template-columns: 1fr; }
    .media-copy { padding-bottom: .15rem; }
    .voice-3d { grid-template-columns: 44px 1fr 44px; }
    .voice-scene { height: 430px; }
    .voice-card { width: min(320px, 72%); padding: 1.15rem 1rem 1rem; }
    .voice-card p { min-height: 0; font-size: .92rem; }
    .visit-map { width: 100%; height: 280px; min-height: 280px; justify-self: stretch; border-inline-start: 0; border-top: 1px solid #eadfce; }
    .media-mosaic { grid-template-columns: 1fr 1fr; grid-template-rows: 180px 120px 120px; }
    .media-mosaic .reel { grid-column: 1 / -1; grid-row: 1; min-height: 180px; }
    .media-mosaic .reel img { height: 100%; min-height: 180px; }
    .quick-contact { left: .7rem; bottom: .7rem; }
    .qc-label { display: none; }
    .qc-item { width: 50px; height: 50px; padding: 0; justify-content: center; border-radius: 16px; overflow: hidden; }
    .qc-mark { width: 100%; height: 100%; border-radius: inherit; }
    .ticker-track span { font-size: .78rem; }
}
